Query: Select InvoiceT total different from GLMovement total

Select [ResInvoiceT].[DBId], [ResInvoiceT].[Number], [ResInvoiceT].[Id], [ResInvoiceT].[Type], [ResGLMovement].*, [ResInvoiceT].[Total] from (Select [GLMovement].[DBId], [GLMovement].[GLPeriodId], [GLMovement].[EntryNumber], [GLMovement].[InvoiceTId], Sum(Round(Case When [CD] = ‘D’ Then [Amount] Else -[Amount] End, 2)) as [Total] from [GLMovement] INNER JOIN [GLAccount] ON ([GLMovement].[GLAccountId] = [GLAccount].[Id] and [GLMovement].[DBId] = [GLAccount].[DBId] and [GLAccount].[Type] = 11) where [GLMovement].[Type] = 1 Group by [GLMovement].[DBId], [GLMovement].[GLPeriodId], [GLMovement].[EntryNumber], [GLMovement].[InvoiceTId]) as [ResGLMovement] … Continue reading Query: Select InvoiceT total different from GLMovement total